//
//  PlayerManager.h
//  MusicDemos
//
//  Created by xalo on 16/6/16.
//  Copyright © 2016年 蓝鸥科技有限公司西安分公司. All rights reserved.
//

#import <Foundation/Foundation.h>

@protocol playManagerDelegate <NSObject>
//滑块播放时间传值
-(void)playManagerDelegateFetchTotalTime:(NSString*)totalTime currentTime:(NSString *)currentTime progress:(CGFloat)progress;
//自动播放到下一首的
-(void)playToNextMusic;
@end

@interface PlayerManager : NSObject

@property (nonatomic,weak)id<playManagerDelegate>delegate;

+(instancetype)defaultManager;
-(void)prepareToPlayMusicWithURL:(NSString *)url;
-(void)playMusic;
-(void)pauseMusic;
-(void)playMusicWithSliderValue:(CGFloat)progress;
-(BOOL)isPlaying;
@end
